package com.wyh.Service.Impl;

import com.wyh.Mapper.UserMapper;
import com.wyh.Service.UserService;
import com.wyh.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserMapperImpl implements UserService {
    @Autowired
    private UserMapper mapper;


    @Override
    public List<User> getUserList() {
        return mapper.getUserList();
    }

    @Override
    public User getUserById(int id) {
        return mapper.getUserById(id);
    }

    @Override
    public int updateUser(User user) {
        return mapper.updateUser(user);
    }

    @Override
    public int addUser(User user) {
        return mapper.addUser(user);
    }

    @Override
    public int deleteUser(int id) {
        return mapper.deleteUser(id);
    }
}
